﻿<%@ Assembly Name="$SharePoint.Project.AssemblyFullName$" %>
<%@ Import Namespace="Microsoft.SharePoint.ApplicationPages" %>
<%@ Register TagPrefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls"
    Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register TagPrefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register TagPrefix="asp" Namespace="System.Web.UI" Assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" %>
<%@ Import Namespace="Microsoft.SharePoint" %>
<%@ Assembly Name="Microsoft.Web.CommandUI, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="GeneralSettings.aspx.cs"
    Inherits="CKS.Sandbox.Admin.Layouts.CKS.Sandbox.Admin.GeneralSettings" DynamicMasterPageFile="~masterurl/default.master" %>

<asp:Content ID="PageHead" ContentPlaceHolderID="PlaceHolderAdditionalPageHead" runat="server">
    <style type="text/css">
        .system
        {
            width: 500px;
        }
        
        .behaviour
        {
            width: 300px;
            height: 25px;
        }
        
        .email        {
            width: 500px;
        }
        
        .dropDown
        {
            float: right;
        }
        
        .clear
        {
            clear: right;
        }
    </style>
</asp:Content>
<asp:Content ID="Main" ContentPlaceHolderID="PlaceHolderMain" runat="server">
    <div style="margin: 10px; padding: 10px;">
        <div style="position: relative; height: 70px;">
            <div style="float: left;">
                <img src="/_layouts/images/CKS.Sandbox.Admin/CKS_Logo_full.gif" alt="Community Kit for SharePoint" />
            </div>
            <div style="float: left; padding-left: 10px;">
                <h2>
                    CKS:Sandbox - General Settings</h2>
                <span style="font-style: italic;">Version:
                    <asp:Literal ID="litVersion" runat="server" /></span>
            </div>
            <div style="clear: left;">
                &nbsp;</div>
        </div>

        <h3>System Settings</h3>
        <div class="system">
                <asp:CheckBox ID="chkEnforceRules" runat="server" Text="Enforce Validation Rules" />
                <p>
                Do you want to enforce your validation rules? Enabling this checkbox means that 
                any solution which fails validation will not be activated and an error message will
                be displayed to the end users.
                </p>
                <div class="clear" />
        </div>
        

        <h3>Validation Behaviour</h3>
        <p>
            <div class="behaviour">
                Assembly: Public Key Token
                <div class="dropDown">
                    <asp:DropDownList ID="ddlTokenBehaviour" runat="server">
                        <asp:ListItem Text="Allow All" Value="Allow" Selected="True" />
                        <asp:ListItem Text="Block All" Value="Block" Selected="False" />
                    </asp:DropDownList>
                </div>
            </div>
            <div class="behaviour">
                Assembly: Name
                <div class="dropDown">
                    <asp:DropDownList ID="ddlAssemblyNameBehaviour" runat="server">
                        <asp:ListItem Text="Allow All" Value="Allow" Selected="True" />
                        <asp:ListItem Text="Block All" Value="Block" Selected="False" />
                    </asp:DropDownList>
                </div>
            </div>
            <div class="behaviour">
                Assembly: Type Namespaces
                <div class="dropDown">
                    <asp:DropDownList ID="ddlTypeNamespaceBehaviour" runat="server">
                        <asp:ListItem Text="Allow All" Value="Allow" Selected="True" />
                        <asp:ListItem Text="Block All" Value="Block" Selected="False" />
                    </asp:DropDownList>
                </div>
            </div>
            <div class="behaviour">
                Solution: ID Number
                <div class="dropDown">
                    <asp:DropDownList ID="ddlSolutionIdBehaviour" runat="server">
                        <asp:ListItem Text="Allow All" Value="Allow" Selected="True" />
                        <asp:ListItem Text="Block All" Value="Block" Selected="False" />
                    </asp:DropDownList>
                </div>
            </div>
            <div class="behaviour">
                Files: Types (File Extensions)
                <div class="dropDown">
                    <asp:DropDownList ID="ddlFileTypes" runat="server">
                        <asp:ListItem Text="Allow All" Value="Allow" Selected="True" />
                        <asp:ListItem Text="Block All" Value="Block" Selected="False" />
                    </asp:DropDownList>
                </div>
            </div>
            <div class="system">
                Note - File RegEx and Text Strings are Allowed by default (otherwise it would be rediculous!). 
                You can create "Deny" rules for these in the Validation Rules.
            </div>

            <h3>Email Settings</h3>
            <div class="email">
                <asp:CheckBox ID="chkEnableEmail" runat="server" Text="Enable Email Notification" AutoPostBack="true" />
                <p>
                Do you want to be emailed when validation fails? Note - you do not have to enforce validation for 
                email notification to work.
                </p>
                <p>
                    Note - Email notification uses the Farm Outgoing Email Settings. If outgoing email is not configured, then this feature will not function!
                </p>
            </div>
            <div class="email">
                Send To Address:<br />
                <asp:TextBox ID="txtEmailSendTo" runat="server" Width="300px" />
                <p>
                This is the email address you would like to send email notifications to. This email address is not validated!
                </p>
            </div>
           

            <p>
                <asp:Button ID="btnSave" runat="server" Text="Save" />
                <asp:Button ID="btnCancel" runat="server" Text="Cancel" />
            </p>
    </div>
</asp:Content>
<asp:Content ID="PageTitle" ContentPlaceHolderID="PlaceHolderPageTitle" runat="server">
    CKS:Sandbox - General Settings
</asp:Content>
<asp:Content ID="PageTitleInTitleArea" ContentPlaceHolderID="PlaceHolderPageTitleInTitleArea"
    runat="server">
    CKS:Sandbox - General Settings
</asp:Content>
